import { splitPrice } from '@/utils/customModule';
import { View } from '@tarojs/components';
import React from 'react';
import styles from './index.module.scss';

const SplitPrice = ({ price, className = '' }) => {
  const [priceLeft, priceRight] = splitPrice(price);

  return (
    <View className={`${styles.SplitPrice} customePageStyle ${className}`}>
      <View className="price-0">¥{price}</View>
      {/* <View className="price-1">{priceLeft}</View>
      <View className="price-2">.{priceRight}</View> */}
    </View>
  );
};

export default SplitPrice;
